package cn.kgc.javaweb.dao;

import cn.kgc.javaweb.entity.User;

import java.sql.SQLException;
import java.util.List;

/**
 * @author: mosin
 * @version: v1.0  2022/9/8
 * 用户信息的数据持久层操作
 */
public interface UserDao {

    User selectByUsername(String username);

    void register(String username, String password);

    User selectByUsernameAndPassword(String username, String password);

    List<User> selectAll();

    Integer add(User user);

    Integer delete(int id);

    Integer updateUser(User user);

    List<User> selectByPage(Integer start, Integer size);

    Integer updateImg(Integer userId, String lastName);
}
